package com.woniuxy.microsystemuapserver.controller;

import com.woniuxy.microsystemuapserver.bean.ResultMsg;
import com.woniuxy.microsystemuapserver.bean.RoleBean;
import com.woniuxy.microsystemuapserver.service.RoleService;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Author: huhenggg
 * @Date: 2021/1/28 0028 下午 7:36
 */
@RestController
@RequestMapping("/role")
public class RoleController {

    @Resource
    private RoleService roleServiceImpl;

    /**
     * 修改角色
     * @param roleBean
     * @return
     */
    @GetMapping("/update")
    public ResultMsg updateRole(RoleBean roleBean) {
        roleServiceImpl.updateRole(roleBean);

        return null;
    }


    /**
     * 新增角色
     * @param roleBean
     * @return
     */
    @GetMapping("/save")
    public ResultMsg saveRole(RoleBean roleBean) {
        roleServiceImpl.updateRole(roleBean);

        return null;
    }

}
